<template>
  <div>
    <ChartsTop :chartData="chartData"></ChartsTop>
    <Chartsmain :x="chartData.orderFullYearAxis"  :saleArr="chartData.orderFullYear" :visiteArr="chartData.userFullYear" :arr="chartData.orderRank" :arr1="chartData.userRank"></Chartsmain>
    <Chartsfooter :searchWord="chartData.searchWord"></Chartsfooter>
  </div>
</template>
<script lang="ts" setup>
import ChartsTop from './chartsTop/index.vue'
import Chartsmain from './chartsmain/index.vue'
import Chartsfooter from './chartsfooter/index.vue'
// 引入请求函数
import { reqChartsData } from '@/api/home/home'
import { onMounted, ref } from 'vue'
let chartData = ref({});
onMounted(async () => {
 let result= await reqChartsData()
 chartData.value=result
 console.log(result)
})

</script>

<style scoped>

</style>
